﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace kairiseiMAParser
{
    public class Enemy_lvup
    {
        public string ID;//#ID
        public string Rank;//レベル
        //レベル上昇値
        public int HP;//HP
        public int ATK;//ATK
        public int INT;//INT
        public int MND;//MND
        public int DEF;//DEF
        public int MDEF;//MDEF
        public int SubtractionDamage;//ダメージ減算
        //
        public int HPbar;//HPバー本数
        //属性倍率
        public int Fire;
        public int Ice;
        public int Wind;
        public int Light;
        public int Dark;
        public int Soil;
        public int Thunder;
        public int Water;
        public int None;
        //
        //バッドステータス耐性割合
        public int Stan;//スタン
        public int Signatureles;//サインレス
        public int Charm;//チャーム
        public int Poison;//毒
        public int Barn;//炎上
        public int Freeze;//凍結
        public int Bleed;//裂風
        public int Undergroundmine;//アンダーマイン
        public int Giventheweakness;//弱点付与
        public int ElectricShock;//感電
        public int Trap;//トラップ
        public int Costlimit;//コスト制限
        public int Reducethenumberofdraw;//ドロー枚数減少(ターン指定)
        //
        public int OneTurnActions;//1ターンの行動回数
        public string PassiveSkillsID;//パッシブスキル
        public Skills normalattack;//通常攻撃
        public Skills[] skill = new Skills[14];
        public Skills[] bigskill = new Skills[5];
        //初期覚醒設定
        public string weizhi;

        public class Skills
        {
            public string SkillID;
            public string AIID;
            public string Priority;
            public string TargetType;
            public string Cost;
            public string Maximum;
            public string Rate;
            public string Failure;
        }

        public Enemy_lvup(string[] str)
        {
            Reader reader = new Reader(str);
            ID = reader.NextString();
            HPbar = reader.NextInt32();
            //属性倍率
            Fire = reader.NextInt32();
            Ice = reader.NextInt32();
            Wind = reader.NextInt32();
            Light = reader.NextInt32();
            Dark = reader.NextInt32();
            Soil = reader.NextInt32();
            Thunder = reader.NextInt32();
            Water = reader.NextInt32();
            None = reader.NextInt32();
            //バッドステータス耐性割合
            Stan = reader.NextInt32();
            Signatureles = reader.NextInt32();
            Charm = reader.NextInt32();
            Poison = reader.NextInt32();
            Barn = reader.NextInt32();
            Freeze = reader.NextInt32();
            Bleed = reader.NextInt32();
            Undergroundmine = reader.NextInt32();
            Giventheweakness = reader.NextInt32();
            ElectricShock = reader.NextInt32();
            Trap = reader.NextInt32();
            //初期覚醒設定
            weizhi = reader.NextString();
            OneTurnActions = reader.NextInt32();
            PassiveSkillsID = reader.NextString();
            normalattack = new Skills();
            normalattack.SkillID = reader.NextString();
            normalattack.AIID = reader.NextString();
            normalattack.Priority = reader.NextString();
            normalattack.TargetType = reader.NextString();
            normalattack.Cost = reader.NextString();
            normalattack.Maximum = reader.NextString();
            normalattack.Rate = reader.NextString();
            normalattack.Failure = reader.NextString();
            for (int i = 0; i < 14; i++)
            {
                skill[i] = new Skills();
                skill[i].SkillID = reader.NextString();
                skill[i].AIID = reader.NextString();
                skill[i].Priority = reader.NextString();
                skill[i].TargetType = reader.NextString();
                skill[i].Cost = reader.NextString();
                skill[i].Maximum = reader.NextString();
                skill[i].Rate = reader.NextString();
                skill[i].Failure = reader.NextString();
            }
            for (int i = 0; i < 5; i++)
            {
                bigskill[i] = new Skills();
                bigskill[i].SkillID = reader.NextString();
                bigskill[i].AIID = reader.NextString();
                bigskill[i].Priority = reader.NextString();
                bigskill[i].TargetType = reader.NextString();
                bigskill[i].Cost = reader.NextString();
                bigskill[i].Maximum = reader.NextString();
                bigskill[i].Rate = reader.NextString();
                bigskill[i].Failure = reader.NextString();
            }
        }
    }
}
